/***************************************************************
*  Copyright (c) 2007 by GroupMe! Team (www.groupme.net)
*  All rights reserved.
*
*  This file is part of the GroupMe! Project. Source code of 
*  this project is closed and redistribution of this code is
*  prohibited. 
*  
*  Contact: http://www.groupme.net
*
*  This copyright notice MUST APPEAR in all copies of the file!
***************************************************************/
package net.groupme.search.manualadd;

import java.io.IOException;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.List;

import net.groupme.controller.model.LocationSearchResult;
import net.groupme.controller.model.SearchResult;
import net.groupme.model.dao.SQLDBController;

import org.junit.Test;
import static org.junit.Assert.*;

/**
 * created on 08.07.2007
 * 
 * This class/interface...
 * 
 * @author Fabian Abel, <a href="mailto:abel@l3s.de">abel@l3s.de</a>
 * @author last edited by: $Author: fabian $
 * 
 * @version $Revision: 1.5 $ $Date: 2007-11-23 12:54:15 $
 */
public class ManualAddOfRessourcesTest{

	/**
	 * Test method for {@link net.groupme.search.manualadd.ManualAddOfRessources#addResourceManual(java.lang.String, java.lang.String, java.lang.String)}.
	 */
	@Test
	public final void testAddResourceManual() {
		//SQLDBController.removeGroupById("33");
		ManualAddOfRessources mad = new ManualAddOfRessources();
		List<SearchResult> results = mad.addResourceManual("http://maps.google.de/maps?f=q&hl=en&geocode=&time=&date=&ttype=&q=Yorckstr.+6+Hannover&sll=51.124213,10.546875&sspn=10.571673,23.203125&ie=UTF8&z=16&iwloc=addr&om=1", "titel", "description");
		assertNotNull(results);
		for(SearchResult res: results){
			assertTrue(res instanceof LocationSearchResult);
			System.out.println("Long: " + ((LocationSearchResult)res).getLongitude());
			System.out.println("Lat: " + ((LocationSearchResult)res).getLatitude());
		}
	}

}
